<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<script type="text/javascript">
$(function(){
    	$("#newpsw2").blur(function(){
    		var  newpsw1 = $("#newpsw1").val();
    		var  newpsw2 = $(this).val();
    		if(newpsw1==newpsw2){
    			 $("span").text("");
    		     $("form").attr("onsubmit","return true");
    		}else{
    			 $("span").text("请确保2次密码一致");
    			 $("form").attr("onsubmit","return false");
    		}
    	});
    });
</script>
</head>
<body>
<form action="DatePsw" method="post">
输入原密码：<input type="password" name="opsw"/>
输入新密码：<input type="password" name="npsw" id="newpsw1"/>
请再次输入：<input type="password" name="apsw" id="newpsw2"/>
<input type="submit" value="提交">
</form>


</body>
</html>